﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SendBoss.aspx.cs" Inherits="Otgruzka.WebForms.SendBoss" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Отправка электронного письма</title>
    <link href="~/Styles/progressbar.css" rel="stylesheet" type="text/css" />
</head>
<script type="text/javascript">
function closeThisWindow(result)
{
    window.top.closeDialog2Window(result);
}
</script>
<%--<style type="text/css">
    #SendMailProgressBar {
      width:80%;
      background-color: #A2A2A2;
      bottom: 80%; left: 10%; position: absolute;
      vertical-align:middle; text-align:center;
    }
</style>--%>
<body>
    <form id="form1" runat="server">
        <asp:ScriptManager ID="scriptManager" runat="server" EnablePageMethods="true" ScriptMode="Release"></asp:ScriptManager>
        <asp:UpdatePanel ID="SendMailUpdatePanel" runat="server">
            <ContentTemplate>
                <table> 
                    <tr>
                        <td style="width:80%;">
                            <div>
                                <h1>Отправка электронного письма</h1>

                                <div class='<%= (ErrorMessage.Text.Length==0) ? "hidden" : "showen" %>'>
                                    <div id="error_string" class="cError"><asp:Label ID="ErrorMessage" runat="server" /></div>
                                </div><br />

                                <div><%= tableOrder %></div>
                                <asp:HiddenField ID="OrderManagerEMail" runat="server" />
                                <asp:HiddenField ID="OrderContactEMail" runat="server" />
                                <asp:HiddenField ID="OrderContactName" runat="server" />
                                <p>
                                    <asp:label AssociatedControlID="EMails" ID="Label1" Text="Адреса e-mail, на которые будет посылаться письмо: " runat="server" />
                                    <asp:TextBox ID="EMails" name="EMails" runat="server" Width="60%" />
                                </p>

                                <%--<p>Комментарий: </p>
                                <div>
                                    <asp:TextBox runat="server" ID="comment" name="comment" TextMode="MultiLine" Width="100%" Height="200"></asp:TextBox>
                                </div>--%>

                                <div>
                                    <asp:Button runat="server" Text="Отправить" ID="SendEMail" name="SendEMail" OnClick="SendEMail_Click" />&nbsp;
                                    <asp:Button runat="server" Text="Закрыть окно" ID="Cancel" OnClientClick="javascript: closeThisWindow();" />
                                </div>
                            </div>
                        </td>
                        <td style="width:20%;">
                            <asp:Repeater ID="PromptMessagesRepeater" runat="server" Visible="false">
                                <ItemTemplate>
                                    <div class="helpdiv" style="margin: 2px;">
                                        <asp:Label ID="id" runat="server"><%# Container.DataItem %></asp:Label>
                                    </div>
                                </ItemTemplate>
                            </asp:Repeater>
                        </td>
                    </tr>
                </table>
            </ContentTemplate>
        </asp:UpdatePanel>
        <asp:UpdateProgress ID="SendMailProgressBar" runat="server" AssociatedUpdatePanelID="SendMailUpdatePanel">
            <ProgressTemplate>
                <div id="closebg">
                    <div id="centered">
                    <%-- <div align="center" valign="middle" runat="server" style="padding-top: 20%; background-color:#F2F2F2; height:35%; width:98%; position:absolute; left:1%; top:10%; visibility:visible; vertical-align:middle; text-align:center; z-index:40;"> --%>
                        <%--<div style="vertical-align:middle;">--%>
                        <asp:Image ID="ProgressImage" runat="server" ImageUrl="~/Images/ajax-loader.gif" style="vertical-align:middle; text-align:center;" AlternateText="Проверяются введенные данные" />
                        <%--</div>--%>
                    <%-- </div> --%>
                    </div>
                </div>
            </ProgressTemplate>
        </asp:UpdateProgress>
    </form>
</body>
</html>